import Vue from 'vue'
import VueRouter from 'vue-router'

Vue.use(VueRouter)

const routes = [{
    path: '/',
    component: () =>
        import('@/views/index.vue')
}]

const router = new VueRouter({
    mode: 'hash',
    routes
})


// 判断是否需要登录权限 以及是否登录
router.beforeEach((to, from, next) => {

    next()
    // const UnionToken = localStorage.getItem('UnionToken')
    // if (!UnionToken) {
    //     next()
    // } else {
    //     next()
    // }
})
export default router